#include "rclcpp/rclcpp.hpp"

#include <iostream>
#include <opencv2/core/mat.hpp>
#include <opencv2/highgui.hpp>
#include <opencv2/opencv.hpp>

int main(int argc, char **argv)
{
    (void)argc;
    (void)argv;

    cv::VideoCapture capture(0);
    if (!capture.isOpened())
    {
        std::cout << "camera open fail" << std::endl;
    }
    cv::Mat img;
    while (capture.read(img))
    {
        cv::imshow("camera", img);
        if (cv::waitKey(1) == 27)
        {
            break;
        }
    }
    capture.release();
    cv::destroyAllWindows();

    return 0;
}